#include "panda_thread.hpp"
#include <cstring>

using namespace Panda;

TaskLocation::TaskLocation( const char* file, const char* func, int line ) {
    this->file_ = file;
    this->func_ = func;
    this->line_ = line;
}

TaskLocation::TaskLocation( TaskLocation& other ) {
    this->file_ = other.file_;
    this->func_ = other.func_;
    this->line_ = other.line_;
}

TaskLocation& TaskLocation::operator=( TaskLocation& other ) {
    this->file_ = other.file_;
    this->func_ = other.func_;
    this->line_ = other.line_;
    return *this;
}

bool TaskLocation::operator == ( const TaskLocation& other ) const {
    return std::strcmp( file_, other.file_ ) == 0 && strcmp( func_, other.func_ ) == 0 && line_ == other.line_;
}